<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>代言人出行首位冠军列表</title>
    <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1.0" />
    <#include "/view/head.html"/>
      <style type="text/css">
        .table-class{
            width:90%;
            text-align: center;
            border:1px solid #afd9ee;
            margin:0 auto;
            margin-top: 50px;
        }
        .list-path{
            height: 50px;
            line-height: 50px;
            background-color: #9acfea;

        }
        table th{
            text-align: center;
            WORD-WRAP: break-word;
            width: 100px;
        }
        table thead tr {
            background-color: #9acfea;
        }
        .table-query{
            /*height: 40px;*/
            /*width:80px;*/
            /*text-align: center;*/
            white-space:nowrap;
            /*position: relative;*/
            float: left;
            display:inherit;
            /*display: inline;*/


        }
        .label-head{
            height: 60px;
            width: 100%;
        }
        .bs-example .input-group{
            width:300px;
            float: left;
            margin-top:20px;

        }
        .bank-label{
            width:25px;
            float: left;
        }
        .label-hidden{
            display: none;
        }
        .panel-body{
            padding-top: 0px;
        }
       /* .input-group{
            margin-top:20px;
        }*/
    </style>
    <script type="text/javascript">

    </script>
</head>
<body>

<div class="list-path" > <span style="margin-left: 50px;"><span class="glyphicon glyphicon-home"></span> 代言人出行首位冠军列表</span></div>

<div class="table-class">

<#include "/view/opermsg.html"/>


    <table class="table table-hover">
        <thead>
        <tr>
            <th colspan="4"><span style="color: green;">请保持有3个数据，表示红色出行代言人冠军，表示橙色出行代言人冠军，表示绿色出行代言人冠军</span></th>
        </tr>
        <tr>
            <th>序号</th>
                <th class="label-hidden">主键</th>
                <th>代言人类型</th>
                <!--<th>用户</th>-->

            <th>操作</th>
        </tr>
        </thead>
        <tbody>
        <#list pagination.list as c>
            <tr>
                <td>${(pagination.pageNo-1)*pagination.pageSize+1+c_index}</td>
                        <td class="label-hidden">${c.firsttripId!}</td>
                            <td>
                                <#if c.represent??>
                                    <#if c.represent==1>
                                        <span class="label label-danger">红色出行代言人</span>
                                        <#elseif c.represent==3>
                                            <span class="label label-warning">橙色出行代言人</span>
                                        <#elseif c.represent==2>
                                            <span class="label label-success">绿色出行代言人</span>
                                    </#if>

                                </#if>
                            </td>

                            <!--<td>${c.userapproveId!}</td>-->


                <td>
                    <a href="${base}/firsttrip/detail.do?firsttripId=${c.firsttripId!}" class="btn btn-primary">详情</a>
                    &nbsp;<a href="${base}/firsttrip/add.do?firsttripId=${c.firsttripId!}" class="btn btn-primary">修改</a>
                    &nbsp;<a href="${base}/firsttrip/delete.do?firsttripId=${c.firsttripId!}" class="btn btn-primary">删除</a>
                </td>
            </tr>


        </#list>
        <#if 0==pagination.totalCount>
            <tr>
                <td colspan="7" style="color: red"> 没有相关数据 </td>
            </tr>
        </#if>




        </tbody>
    </table>
        <!--<span style="text-align: left"> <a href="#" class="btn btn-primary">新增</a></span>-->
    <ul class="pagination" >

    <#if pagination??>
        <#if pagination.pageNo gt 1>
                <li><a href="javascript:setPage(1,#{pagination.pageSize})">首页</a></li>
        </#if>
            <#list 5..1 as t>
                <#if (pagination.pageNo-t gt 0)>
                    <li><a href="javascript:setPage(#{pagination.pageNo-t},#{pagination.pageSize})">#{pagination.pageNo-t}</a></li>
                </#if>
            </#list>
            <li><a href="#" style="background-color: #ddd;">#{pagination.pageNo}</a></li>
            <#list 1..5 as t>
                <#if (pagination.totalPage gt pagination.pageNo+t-1)>
                    <li><a href="javascript:setPage(#{pagination.pageNo+t},#{pagination.pageSize})">#{pagination.pageNo+t}</a></li>
                </#if>
            </#list>
            <#if pagination.totalPage gt pagination.pageNo>
                <li><a href="javascript:setPage(#{pagination.totalPage},#{pagination.pageSize})">尾页</a></li>
            </#if>

        </#if>

    </ul>
    <div style="position: fixed;float: left;margin-left: 50px;">
        <a href="${base}/firsttrip/add.do" class="btn btn-primary">新增</a>
    </div>

</div>
<script>
    function setPage(pageNo,pageSize){
        var href = "${base}/firsttrip/list.do?";

            href+='represent='+$('#represent').val()+"&";

            href+='userapproveId='+$('#userapproveId').val();

        href+="&pageNo="+pageNo;
        href+="&pageSize="+pageSize;
        location.href=href;
    }

</script>

</body>
</html>
